import { TaskHandler } from "../types";
import { figmaFetchRawTask } from "./figma.fetchRaw";
import { figmaMinifyTask } from "./figma.minify";
import { tokensExtractTask } from "./tokens.extract";
import { summaryGenerateTask } from "./summary.generate";
import { blueprintCheckTask } from "./blueprint.check";
import { fieldnodeCoverageTask } from "./fieldnode.coverage";
import { previewValidateTask } from "./preview.validate";
import { renderVerifyBelongToTask } from "./render.verifyBelongTo";

export const tasks: Record<string, TaskHandler> = {
  "figma.fetchRaw": figmaFetchRawTask,
  "figma.minify": figmaMinifyTask,
  "tokens.extract": tokensExtractTask,
  "summary.generate": summaryGenerateTask,
  "blueprint.check": blueprintCheckTask,
  "fieldnode.coverage": fieldnodeCoverageTask,
  "preview.validate": previewValidateTask,
  "render.verifyBelongTo": renderVerifyBelongToTask,
};

export function listTasks() {
  return Object.keys(tasks);
}
